<?php 
namespace Admin\Controller;
use Think\Controller;
class MemberController extends BaseController{
	function member(){
		$UserOb=M('User');
		$arr=$UserOb->select();
		$this->assign('arr',$arr);
		$this->display();
	}
	function member_upd(){
		$UserOb=M('User');
		if ($_GET['state']==0) {
			$arr = array('user_state'=>1);
			$re=$UserOb->where("user_id={$_GET['id']}")->data($arr)->save();
		}else{
			$arr = array('user_state'=>0);
			$re = $UserOb->where("user_id = {$_GET['id']}")->data($arr)->save();
		}
		if($re){
			echo 1;
		}
	}
}